<!DOCTYPE html>
<html lang="en" xmlns:th="http://www.thymeleaf.org">
<head>
    <meta charset="utf-8">
    <title>文件搜索页</title>
    <link rel="icon" type="image/x-icon" href="/images/logoRed.ico">
    <meta name="renderer" content="webkit">
    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
    <meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=0">
    <link rel="stylesheet" th:href="@{/static/layuiadmin/layui/css/layui.css}" media="all">
    <link rel="stylesheet" th:href="@{/static/layuiadmin/style/admin.css}" media="all">
    <link rel="stylesheet" th:href="@{/static/css/formSelects-v4.css}" media="all">
    <link rel="stylesheet" th:href="@{/static/css/common.css}">
    <style type="text/css">
        body {
            font-family: arial;
            font-size: 12px;
        }

        #topbar { /*id选择器*/
            text-align: right;
            font-sixe: 13px;
            margin-top: 18px;
            padding-right: 5px;
        }

        #topbar1 a {
            color: #999;
            margin-left: 25px;
            margin-top: 18px
        }

        #topbar2 a {
            color: #999;
        }
        /*#topbar0 span{
        color:#999;
        }8*/
        #topbar2 span {
            color: #999;
        }

        #topbar a {
            color: #333;
            margin-left: 20px;
        }

        .bola {
            font-weight: 700;
        }

        #topbar #morepro {
            background: #2d78f4;
            color: #fff;
            padding: 3px;
        }

        .centerdiv {
            height: 100%;
            text-align: center;
        }

        #searchText {
            width: 512px;
            height: 16px;
            padding: 12px 16px;
            font-size: 16px;
            margin: 0px -10px 0px 0px;
            vertical-align: top;
            outline: 0;
            box-shadow: none;
            border-radius: 10px 0 0 10px;
            border: 2px solid #c4c7ce;
            background: #fff;
            color: #222;
            overflow: hidden;
            box-sizing: content-box;

        }
        .s_ipt_wr {
            position: relative;
            width: 546px;
        }
        .s_btn_wr {
            width: 108px;
            height: 44px;
            position: relative;
            z-index: 2;
            display: inline-block;
            *display: inline;
            zoom: 1;
            background: 0 0;
            vertical-align: top;
            *vertical-align: middle;
        }
        .s_btn {
            cursor: pointer;
            width: 108px;
            height: 44px;
            line-height: 45px;
            line-height: 44px\9;
            padding: 0;
            background: 0 0;
            background-color: #4e6ef2;
            border-radius: 0 10px 10px 0;
            font-size: 17px;
            color: #fff;
            box-shadow: none;
            font-weight: 400;
            border: none;
            outline: 0;
        }
        #submitBtn {
            width: 100px;
            height: 36px;
            background: #3385ff;
            color: #fff;
            border: none;
        }

        .iconCls0 {
            display: inline-block;
            width: 14px;
            height: 17px;
            background: url(icons_5859e57.png) -600px -95px;
        }

        .iconCls {
            display: inline-block;
            width: 14px;
            height: 17px;
            background: url(icons_5859e57.png) -624px -95px;
        }
    </style>
</head>
<body>
<div class="layui-fluid" style=" background-color: #FFFFFF;">
        <div class="centerdiv" style="margin-top: 135px;margin-bottom: 20px;">
            <img src="/static/images/logoRed.png" style="width: 100px; height: 100px;"><h1>文件服务器</h1>
        </div>
        <div class="centerdiv">
                <div class="layui-form">
                    <span class="s_ipt_wr">
                        <input id="searchText" name="KW" autocomplete="off" maxlength="100" placeholder="文件名/文件夹名/关键字">
                    </span>
                    <span class="btn_wr s_btn_wr bg" id="s_btn_wr">
                        <input type="button" value="查找文件" id="su" class="btn self-btn bg s_btn">
                    </span>
                </div>
        </div>
        <div class="centerdiv" style="margin-top: 560px">
        </div>
        <div class="centerdiv">
            <span style="color: #666;"></span>
        </div>
        <div id="topbar1" class="centerdiv" style="margin-top: 20px">

        </div>
        <div id="topbar2" class="centerdiv" style="margin-top: 8px">
            <span>@2017精英</span>  <span>石家庄裕华区东岗路75号</span>
            <span class="iconCls0"></span>
            <span>精英未来学校</span>
        </div>
</div>
<script th:src="@{/static/layuiadmin/layui/layui.all.js}"></script>
<script th:src="@{/static/js/formSelects-v4.js}"></script>
<script th:src="@{/static/js/base64.min.js}"></script>
<script th:src="@{/static/js/jquery.js}"></script>
<script>
    function search(){
        var searchText=$("#searchText").val();
        if(searchText=='' || searchText == null){
            return;
        }else{
            window.location.href = "/search/"+encodeURIComponent(Base64.encode(searchText));
        }
    }
    $(function(){
        //输入跳转的页面时，监控回车键
        $('input').keydown(function (e) {
            if(e.key=="Enter") {
                //setFormListSubmit是要触发的事件
                search();
            }
        })
    })

    // 搜索
    $('#su').click(function () {
        search();
    });
</script>
</body>
</html>
